package com.ailesson.video.service;

import com.ailesson.video.model.dto.ExcErrorInfoDto;
import com.baomidou.mybatisplus.extension.service.IService;
import com.ailesson.common.reply.PageResult;
import com.ailesson.video.entity.SubjectEntity;
import com.ailesson.video.model.req.SubjectQueryReq;
import com.ailesson.video.model.req.SubjectReq;
import com.ailesson.video.model.reply.SubjectReply;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;
import java.util.List;

/**
 * 课程科目
 *
 * @author mac
 * @email mac@gmail.com
 * @date 2024-09-30 23:08:10
 */
public interface SubjectService extends IService<SubjectEntity> {

    /**
     * 分页查询
     * @param params
     * @return
     */
    PageResult queryPage(SubjectQueryReq params);

    /**
     * 查询信息
     * @param id
     * @return
     */
    SubjectReply info(Long id);

    /**
     * 更新信息
     * @param subject
     */
    void update(SubjectReq subject);

    /**
     * 新增
     * @param subject
     */
    Long add(SubjectReq subject);

    List<SubjectReply> getChildSubject(Long id);

    void exportData(HttpServletResponse response);

    List<ExcErrorInfoDto> importData(MultipartFile file);

}

